package com.javafactroy.kunlong.data.service;

import com.javafactroy.kunlong.data.dao.mysql.DrUserEmpsApiMapper;
import com.javafactroy.kunlong.data.entity.DrUserEmpsApiEntity;
import com.javafactroy.kunlong.base.dto.TQueryParam;
import com.javafactroy.kunlong.base.model.ReturnPageInfo;

import org.apache.ibatis.annotations.Param;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

/**
*  @author raymond.lei@163.com
*  @date   2023-11-30 11:22:45

*/
@Slf4j
@Service
public class DrUserEmpsService extends GeneralService<DrUserEmpsApiEntity, DrUserEmpsApiMapper> {

    public DrUserEmpsService() {
        genricParam = () -> new DrUserEmpsApiEntity();
    }

    public ReturnPageInfo<DrUserEmpsApiEntity> queryParam(@Param("queryParam") TQueryParam<DrUserEmpsApiEntity> queryParam) {
        if ( queryParam.getParam() == null ) {
            queryParam.setParam(new DrUserEmpsApiEntity());
        }

        return super.queryParam(queryParam);

    }
}
